import request from '@/utils/request'

export function getCropProperty(data){ 
  return request({
      url: `/cropProperty/list/${data.cropId}`,
      method: 'get',  //query
    })
}

export function addCropProperty(data){ 
  return request({
      url: `/cropProperty/add`,
      method: 'post',
      data:data   //body
    })
}

export function updateCropProperty(data){ 
  return request({
      url: `/cropProperty/update`,
      method: 'post',
      data:data
    })
}

export function deleteCropProperty(data){ 
  return request({
      url: `/cropProperty/delete/${data.cropPropertyId}`,
      method: 'post',
    })
}

export function deletePropertyList(data){ 
  return request({
      url: `/cropProperty/deleteList?ids%5B%5D=${data.item}`,
      method: 'post',
    })
}